home *** CD-ROM | disk | FTP | other *** search
-
- /*© Copyright 1988-1993 UserLand Software, Inc. All Rights Reserved.*/
-
- #include "iacinternal.h"
-
-
-
- Boolean IACpushrecordparam (AERecord * val, OSType keyword) {
-
- return (IACpushrecorditem (IACglobals.event, val, keyword));
- } /*IACpushrecordparam*/
-
-
- Boolean IACreturnrecord (AERecord *val) {
-
- return (IACpushrecorditem (IACglobals.reply, val, keyDirectObject));
- } /*IACreturnrecord*/
-
-
- Boolean IACgetrecordparam (OSType keyword, AERecord *val) {
-
- if (!IACgetrecorditem (IACglobals.event, keyword, val)) {
-
- IACparamerror (IACglobals.errorcode, "\precord", keyword);
-
- return (false);
- }
-
- IACglobals.nextparamoptional = false; /*must be reset for each param*/
-
- return (true);
- } /*IACgetrecordparam*/
-
-
- Boolean IACgetrecorditem (AEDescList *list, long n, AERecord *val) {
-
- register OSErr ec;
-
- DescType key;
-
- Size actualSize;
-
- if ((*list).descriptorType != typeAEList) {
-
- ec = AEGetKeyDesc (list, n, typeAERecord, val);
-
- if (ec != errAEDescNotFound)
- goto done;
- }
-
- ec = AEGetNthDesc (list, n, typeAERecord, &key, val);
-
- done:
-
- IACglobals.errorcode = ec;
-
- return (ec == noErr);
- } /*IACgetrecorditem*/
-
-
- Boolean IACpushrecorditem (AEDescList *list, AERecord *x, long n) {
-
- register OSErr ec;
-
- if ((*list).descriptorType != typeAEList)
- ec = AEPutKeyDesc (list, n, x);
- else
- ec = AEPutDesc (list, n, x);
-
- IACglobals.errorcode = ec;
-
- AEDisposeDesc (x);
-
- (*x).descriptorType = typeNull;
-
- (*x).dataHandle = NULL;
-
- return (ec == noErr);
- } /*IACpushrecorditem*/
-
-
- Boolean IACnewrecord (AERecord *record) {
-
- register OSErr ec;
-
- ec = AECreateList (NULL, (Size) 0, true, record);
-
- IACglobals.errorcode = ec;
-
- return (ec == noErr);
- } /*IACnewrecord*/
-
-
- Boolean IACgetiteminfo (AERecord *record, long n, AEKeyword *key, DescType *type, Size *bytes) {
-
- register OSErr ec;
-
- ec = AEGetNthPtr (record, n, typeWildCard, key, type, NULL, (Size) 0, bytes);
-
- IACglobals.errorcode = ec;
-
- return (ec == noErr);
- } /*IACgetiteminfo*/
-
-
-
-